ChatGPT Scope
AutomatR.ChatGPT.Activities.ChatGPTScope
The "ChatGPT Scope" activity in AutomatR serves as a scope for executing activities related to the ChatGPT service. This scope enables users to authenticate with the OpenAI API, providing a token for authorization, and perform various operations using the ChatGPT model.
Properties
Name | Description |
---|---|
Input | |
API Token | Allows you to enter the API token (or API key) used for authentication and authorization with the OpenAI API services. This token enables you to make API requests and interact with the OpenAI models. String variables containing the API token. |
Misc | |
Display Name | This property allows you to customize the display name of the activity within the workflow. |
Optional | |
Delay | Specifies the amount of time (in seconds) to wait before executing the "ChatGPT Scope" activity. This can be useful for handling synchronization issues. Integer variables containing the delay duration. Example: If the amount of time is 1000 milliseconds or 1 sec, i.e., 1. |
Scope Internal scope for executing activities related to ChatGPT. Ensure that ChatGPT activities are placed inside this scope for proper execution.
Important Notes
- Ensure that the "ChatGPT Scope" activity is used to wrap ChatGPT-related activities, providing a dedicated context for executing tasks related to ChatGPT.
- The API token is crucial for authentication and should be obtained from OpenAI. Ensure that the provided token is valid for successful execution.
How to use:
- Drag and drop the "ChatGPT Scope" activity onto the workflow.
- Configure the API token property by providing the API key obtained from OpenAI.
- Optionally, configure the delay before executing the scope.
- Place ChatGPT-related activities inside the scope for proper execution.
Example: Consider an example where the "ChatGPT Scope" activity is used to execute ChatGPT-related activities:
ChatGPT Scope:
API Token: "<Your-API-Token>"
Delay: 2
- ChatGPT Generate Response:
Input Text: "Tell me a joke."
Output Result: jokeResponse
- ChatGPT Generate Response:
Input Text: "Explain the concept of artificial intelligence."
Output Result: aiExplanation
In this example, the "ChatGPT Scope" activity is configured with an API token and a delay of 2 seconds. Inside the scope, two "ChatGPT Generate Response" activities are executed to generate responses for different input texts. The results are stored in the variables "jokeResponse" and "aiExplanation" for further use in the workflow.